from rest_framework import serializers
from .models import TeacherChangeClassRecord, ClassroomSchedule

read_only = ['created_at', 'updated_at', 'revstatus']

class TeacherChangeClassRecordSerializer(serializers.ModelSerializer):
    class Meta:
        model = TeacherChangeClassRecord
        # 仅包含以下字段
        fields = "__all__"
        read_only_fields = read_only  # 确保read_only是一个有效的变量或在使用前定义它

class ClassroomScheduleSerializer(serializers.ModelSerializer):
    class Meta:
        model = ClassroomSchedule
        fields = "__all__"



